-- Tools Panel
local PANEL = {}

function PANEL:Init()
	
	self.mountchecked_button = vgui.Create( "DButton", self )
	self.mountchecked_button:SetText( "Mount checked scripts" )
	self.mountchecked_button:SetDrawBorder( false )
	self.mountchecked_button.DoClick = inscript.MenuCall_MountChecked
	
	self.mountchecked_image = vgui.Create( "DImage", self )
	self.mountchecked_image:SetImage( "inscript/indicator_3" )	
	
	
	
	self.reload_button = vgui.Create( "DButton", self )
	self.reload_button:SetText( "Reload scripts" )
	self.reload_button:SetDrawBorder( false )
	self.reload_button.DoClick = inscript.MenuCall_Reload
	
	self.reload_image = vgui.Create( "DImage", self )
	self.reload_image:SetImage( "gui/silkicons/arrow_refresh" )	
	
end


function PANEL:PerformLayout()
	self:SetTall( 18 )
	
	self.mountchecked_image:SetTall( 16 )
	self.mountchecked_image:SetWide( 16 )
	self.mountchecked_image:CenterVertical()
	
	self.mountchecked_button:SizeToContents()
	self.mountchecked_button:SetWide( self.mountchecked_button:GetWide() + 16 )
	self.mountchecked_button:SetTall( 16 )
	self.mountchecked_button:CenterVertical()	
	
	self.mountchecked_image:AlignLeft( 19 )
	self.mountchecked_button:AlignLeft( 19 + 16 + 3 )
	
	
	
	self.reload_image:SetTall( 16 )
	self.reload_image:SetWide( 16 )
	self.reload_image:CenterVertical()
	
	self.reload_button:SizeToContents()
	self.reload_button:SetWide( self.reload_button:GetWide() + 16 )
	self.reload_button:SetTall( 16 )
	self.reload_button:CenterVertical()	
	
	self.reload_image:AlignRight( 3 )
	self.reload_button:AlignRight( 3 + 16 + 3 )

end



vgui.Register( "InsTools", PANEL, "DPanel" )